<?php
	header("Content-Type: text/html;charset=utf-8");
	include("function/_nosql.php"); //
	include("function/function.php");
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>IVV步道_<?= $web_titles ?></title>
<meta name="Keywords" content="IVV步道,<?= $web_keywords ?>" />
<meta name="Description" content="<?= $web_description ?>" />
<link rel="stylesheet" href="css/common.css"/>
<link rel="stylesheet" href="css/style.css"/>
<link rel="stylesheet" href="css/jquery.lightbox.css">
</head>
<body>
    <!--top-bar begin-->
	<? include("_include.top.topbar.php") ?>
    <!--top-bar end-->
    <!--header begin-->
	<? include("_include.top.navbar.php") ?>
    <!--header end-->
    <!--banner begin-->
    <div class="inner-banner">
        <div class="inner-pic"><img src="images/ban2.jpg" alt=""/></div>
        <!--<div class="search-box">
			<form name="SearchForm" id="SearchForm" method="post" action="active_search.php">
            <input type="text" class="search-text input_wby" holdplace="搜索目的地/攻略/活动" name="search_text"/>
            <input type="submit" class="search-send" value=""/>
			</form>
        </div>-->
    </div>
    <!--banner end-->
    <!--活动 begin-->
    <div class="f-item-box">
        <div class="content">
            <div class="breadcrumb"><a href="index.php">首页</a>&gt;<a href="trailivv.php">步道</a>&gt;<a href="trailivv.php">IVV步道</a></div>
            <div class="bd-content">
                <div class="con-pane on">
                    <div class="g-con">
                        <div class="g-con-item">
                            <div class="g-title">
                                <h3><?=getClassName("kboy_news","news_title","news_bigclass=80")?></h3>
                                <div class="line"></div>
                            </div>
                            <div class="history_con">
                                <div class="con">
                                    <?=getClassName("kboy_news","news_content","news_bigclass=80")?>
                                </div>
                                <div class="more" style="display:none"><a href="javascript:;">展开&gt;&gt;</a></div>
                            </div>
                        </div>
                        <div class="g-con-item">
                            <div class="g-title">
                                <h3>活动照片展示</h3>
                                <div class="line"></div>
                            </div>
                            <div class="cva-box-4">
                                <ul>
						<?php
								$SQL = "";
								$pagesize = 12; // 分页数量
								$pageval = chkstr(trim($_REQUEST['page'])); // 获取Page的值
								if($pageval){
									if(!is_numeric($pageval)){
										echo erro("Page Error");
									}
									if($pageval <= 1){
										$pageval = 1;
									}
									$page = ($pageval-1) * $pagesize;
									$page .= ",";
								}else{
									$pageval = 1;
								}
								
								$pagesql = "select * from kboy_news where news_bigclass=81 order by news_top desc,news_order desc, id desc";

								$pagenum = mysql_num_rows(mysql_query($pagesql)); // 总记录数
								$pagecount = ceil($pagenum/$pagesize); // 共分多少页
								if($pageval > $pagecount){
									$pageval = $pagecount;
								}
								
								$news_sql = $pagesql." limit $page $pagesize";
								$news_rows = mysql_query($news_sql);
								$i = 1;
								while($news_rs = mysql_fetch_array($news_rows)){
						?>
                                    <li>
                                        <a href="<?=$news_rs['news_pic']?>?lightbox[width]=990&lightbox[height]=510" class="lightbox" rel="list2">
                                            <div class="pic"><img src="<?=$news_rs['news_pic']?>" width="330" height="170" alt=""/></div>
                                            <p><?=$news_rs['news_title']?></p>
                                        </a>
                                    </li>
						<?php
								}
						?>
									
                                </ul>
                            </div>
						<?php
						
								if($pagenum > $pagesize){
									echo "<div class=\"pagination\"><ul>";
									$url = "trailivv.php?";//当前页面
									pagebar($pagecount, $pageval, 7, $url);
									echo "</ul></div>";
								}
						?>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>
	<!--foot begin-->
	<? include("_include.bottom.footbar.php") ?>
	<!--foot begin-->
	<!--左侧悬浮 begin-->
	<? include("_include.bottom.leftbar.php") ?>
	<!--左侧悬浮 end-->
	<!--右侧悬浮导航 begin-->
	<? include("_include.bottom.rightbar.php") ?>
	<!--右侧悬浮导航 end-->
    <script type="text/javascript" src="js/jquery.min.js"></script>
    <script type="text/javascript" src="js/jquery.SuperSlide.2.1.1.js"></script>
    <script type="text/javascript" src="js/main.js"></script>
    <script type="text/javascript" src="js/jquery.lightbox.min.js"></script>
    <script type="text/javascript">
        jQuery(document).ready(function($){
            $('.lightbox').lightbox();
        });
    </script>
</body>
</html>
